load("@npm//@bazel/typescript:index.bzl", "ts_library")

package(default_visibility = ["//:__subpackages__"])

ts_library(
    name = "aead",
    srcs = [
        "aead.ts",
        "aead_config.ts",
        "aead_key_templates.ts",
        "aead_wrapper.ts",
        "aes_ctr_hmac.ts",
        "aes_ctr_hmac_aead_key_manager.ts",
        "aes_ctr_hmac_aead_key_templates.ts",
        "aes_gcm.ts",
        "aes_gcm_key_manager.ts",
        "aes_gcm_key_templates.ts",
        "index.ts",
        "wrapper.ts",
    ],
    module_name = "tink-crypto/aead",
    deps = [
        "//aead/internal",
        "//exception",
        "//internal",
        "//internal:proto",
        "//subtle",
    ],
)

ts_library(
    name = "aead_tests",
    testonly = True,
    srcs = [
        "aead_config_test.ts",
        "aead_key_templates_test.ts",
        "aead_wrapper_test.ts",
        "aes_ctr_hmac_aead_key_manager_test.ts",
        "aes_ctr_hmac_aead_key_templates_test.ts",
        "aes_gcm_key_manager_test.ts",
        "aes_gcm_key_templates_test.ts",
    ],
    deps = [
        ":aead",
        "//aead/internal",
        "//exception",
        "//internal",
        "//internal:proto",
        "//subtle",
        "//testing/internal",
        "@npm//@types/jasmine",
    ],
)
